package t10086.Data.Map;

import java.io.Serializable;

public class MapGrid implements Serializable {
    private GridType gridType;//网格类型
    private String robotSerialNumber;//指向的机器人序列号
    private int robotCount;//网格上的机器人数量,暂时弃用

    public MapGrid(GridType gridType, String robotSerialNumber) {
        this.gridType = gridType;
        this.robotSerialNumber = robotSerialNumber;
        this.robotCount = 0;
    }
    public MapGrid() {
        this.gridType = GridType.NULL;
        this.robotSerialNumber = null;
        this.robotCount = 0;
    }
    public  void plusOne(){
        this.robotCount++;
    }
    public  void minusOne(){
        this.robotCount--;
    }
    public  GridType getGridType() { return gridType; }
    public String getRobotSerialNumber() { return robotSerialNumber; }
    public  void setGridType(GridType gridType) { this.gridType = gridType; }
    public void setRobotSerialNumber(String robotSerialNumber) { this.robotSerialNumber = robotSerialNumber; }
    @Override
    public String toString() {
        return "MapGrid [gridType=" + gridType +", robotCount="+robotCount+ ", robotSerialNumber="+robotSerialNumber+"]";
    }

    public  int getRobotCount() {
        return robotCount;
    }

    public void setRobotCount(int robotCount) {
        this.robotCount = robotCount;
    }
}
